{% extends "html/settings/base.html" %}

{% block title %}Account Settings{% endblock %}
{% block page_id %}account-settings-page{% endblock %}

{% block settings_main %}
<form method="post" action="/settings">
    <div class="buttons buttons-top">
        <button type="submit">Save</button>
        <a href="/"><button>Cancel</button></a>
    </div>
    <div class="section">
        <h2>Change Auto-Save Interval</h2>
        <div>
            Minutes:
            <select name="autosave">
                {% for i, selected in autosave_intervals %}
                <option{{ selected }}>{{ i }}</option>
                {% endfor %}
            </select>
        </div>
    </div>
    <div class="section">
        <h2>Change Password</h2>
        <div id="passwd">
            <div>
                <label for="old-pass">Old password</label>
                <input type="password" name="old-pass" />
            </div>
            <div>
                <label for="new-pass">New password</label>
                <input type="password" name="new-pass" />
            </div>
            <div>
                <label for="retype-pass">Retype new password</label>
                <input type="password" name="retype-pass" />
            </div>
        </div>
    </div>

    {% if true %}
    <div class="section">
        <h2>Change E-mail Address</h2>
        
        <div>
            <div>
                <label>Current e-mail</label>
                {{ email_address }} {{ email_confirmed }}
            </div>
            <div>
                <label for="new-email">New e-mail</label>
                <input type="text" name="new-email" class="c1" />
            </div>
        </div>
    </div>
    {% endif %}
    <div class="buttons">
        <button type="submit">Save</button>
        <a href="/"><button>Cancel</button></a>
    </div>
</form>
{% endblock %}
